import {createRouter, createWebHashHistory} from 'vue-router'

const routes = [
    {
        path: "/home",
        name: "Home",
        component: () => import("@/views/Home.vue"),
        children: {}
    }, {
        path: "/about",
        name: "About",
        component: () => import("@/views/About.vue")
    }, {
        path: "/login",
        name: "login",
        component: () => import("@/views/Login.vue")
    }, {
        path: "/",
        name: "index",
        component: () => import("@/views/user/Index.vue")
    }, {
        path: "/register",
        name: "register",
        component: () => import("@/views/user/Register.vue")
    }, {
        path: "/login",
        name: "login",
        component: () => import("@/views/Login.vue")
    }, {
        path: "/shopcart",
        name: "shopcart",
        component: () => import("@/views/user/ShopCart.vue")
    },
    {
        path: "/productDetails",
        name: "productDetails",
        component: () => import("@/views/user/ProductDetails.vue")
    },
    {
        path: "/userAddress",
        name: "userAddress",
        component: () => import("@/views/user/UserAddress.vue")
    }
];

const router = createRouter({
    history: createWebHashHistory(),
    routes
})

export default router;
